const {  exec } = require('child_process');
const iconv = require('iconv-lite');

// 封装方法库
export default {
  voice: (e, msg, Rate) => {
    exec(`powershell.exe Add-Type -AssemblyName System.speech; $speak = New-Object System.Speech.Synthesis.SpeechSynthesizer; $speak.Rate = ${Rate}; $speak.Speak([Console]::In.ReadLine()); exit`)
    .stdin.end(iconv.encode(msg, 'gbk'));
  },
  compositeVideo: () => {


  }
}
